
//
//  HHPLiveVideoDefine.h
//  HHPLiveVideo
//
//  Created by 韩红坡 on 2017/4/17.
//  Copyright © 2017年 韩红坡. All rights reserved.
//

#ifndef HHPLiveVideoDefine_h
#define HHPLiveVideoDefine_h

#define BaseUrlString @"http://live.9158.com/"

//生成URL全
#define GenerateUrlString(url) [(BaseUrlString) stringByAppendingPathComponent:(url)]

//所有的view的背景色
#define ViewBgColor RGB(248, 248, 248)

// 屏幕尺寸
#define ScreenBounds [UIScreen mainScreen].bounds
#define ScreenWidth [UIScreen mainScreen].bounds.size.width
#define ScreenHeight [UIScreen mainScreen].bounds.size.height

//RGB进制颜色值
#define RGB(r,g,b)     [UIColor colorWithRed:(r)/255.0f green:(g)/255.0f blue:(b)/255.0f alpha:1]

//带透明度的RGB颜色值
#define RGBA(r,g,b,a)  [UIColor colorWithRed:(r)/255.0f green:(g)/255.0f blue:(b)/255.0f alpha:(a)]

// 字体 4s 4 5 5s 5c与6以上区别
#define HHPFONTSCALE(orginFont) (ScreenHeight > 480 ? (ScreenHeight > 667 ? (orginFont + 2) : (orginFont + 1)) : orginFont)
//字体大小适配
#define Font(fontSize) [UIFont systemFontOfSize:HHPFONTSCALE(fontSize)]
//高度适配缩放比例 4s 4 5 5s 5c与6以上区别
#define HHPLayoutRate(orginLayout) (ScreenHeight > 568 ? (orginLayout) : 0.85 * (orginLayout))

//根据屏幕实际尺寸适配X和Y
// 适配X轴方向
#define KScaleX(x) (ScreenWidth/375.0 * (x))
// 适配Y轴方向
#define KScaleY(y) (ScreenHeight/667.0 * (y))

// 调试模式
#ifdef DEBUG
    #define HHPLog(...) NSLog(__VA_ARGS__);
#else
    #define HHPLog(...);
#endif

#endif /* HHPLiveVideoDefine_h */
